/*
 * jpeg.h
 *
 *
 *
 *
 *
 *
 *
 *
 */
#include "../mmn/DrawTool.h"

#ifndef JPEG_H
#define JPEG_H

typedef struct 
{
/* read only */
	unsigned long Width;		// width in pixels
	unsigned long Height;		// height in pixels
	unsigned char data;	// the raw data of pixels in scanline order
}	TJpeg;

//int DrawJpeg(const TCanvas *canvas, unsigned char *BufferPtr, unsigned long Width, unsigned long Height, int x, int y, char * filename);
TJpeg DrawJpeg(const TCanvas *canvas, int x, int y, char * filename);
TJpeg DrawJpegRemBG(const TCanvas *canv, int x, int y, char * filename, int RGB_R, int RGB_G, int RGB_B );
TJpeg DrawJpegCenter(const TCanvas *canv, TRect *rect, char * filename);
TJpeg GetJpegPtr(char * filename);
TJpeg DrawJpegBuf(const TCanvas *canv, int x, int y, char *jpbuffer);
TJpeg DrawJpegBufRmBG(const TCanvas *canv, int x, int y, char *jpbuffer, int RGB_R, int RGB_G, int RGB_B );
TJpeg GetJpegPtrBuf(char * jpbuffer);

#endif /* JPEG_H */
